]> permondes.de Git - Analog_Engine.git/blame_incremental - scripts/EP1 10.01 Damped Harmonic Oscillator.LACE
Further examples of harmonic oscillation
[Analog_Engine.git] / scripts / EP1 10.01 Damped Harmonic Oscillator.LACE
... / ...
CommitLineData
1# Damped_Oscillator
2# phi'' = -(S*phi + D/m*phi')
3
4coefficient.1(-1) -> -phi0 # Initial Amplitude
5coefficient.3 -> S # SpringForce
6coefficient.4 -> D/m # Damping linear to speed
7
8iintegrate phi'' -> -phi'
9invert -phi' -> phi'
10cmultiply phi', D/m -> D/m*phi'
11
12iintegrate -phi' -> phi
13 IC: -phi0
14cmultiply S, phi -> S*phi
15
16isum 10:S*phi, D/m*phi' -> -(Sphi+D/mphi')
17assign -(Sphi+D/mphi') -> phi''
18
19output(y) -> out.y